using System;
using System.Data.Entity.ModelConfiguration;
using System.Data.Common;
using System.Data.Entity;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using DomainLayer.Data.Entities;

namespace Infrastructure.Data.Mapping
{
	public class FMS_FlowOperatorLogMap : EntityTypeConfiguration<FMS_FlowOperatorLog>
	{
		public FMS_FlowOperatorLogMap()
		{
			// Primary Key
			this.HasKey(t => t.LogID);

			// Properties
			this.Property(t => t.Operation)
				.HasMaxLength(200);
				
			this.Property(t => t.Result)
				.HasMaxLength(200);
				
			this.Property(t => t.OperatorName)
				.HasMaxLength(100);
				
			this.Property(t => t.AudiDesc)
				.HasMaxLength(500);
				
			// Table & Column Mappings
			this.ToTable("FMS_FlowOperatorLog");
			this.Property(t => t.LogID).HasColumnName("LogID");
			this.Property(t => t.BizOrderNo).HasColumnName("BizOrderNo");
			this.Property(t => t.BizOrderType).HasColumnName("BizOrderType");
			this.Property(t => t.FlowId).HasColumnName("FlowId");
			this.Property(t => t.CreateSign).HasColumnName("CreateSign");
			this.Property(t => t.Operation).HasColumnName("Operation");
			this.Property(t => t.Result).HasColumnName("Result");
			this.Property(t => t.Status).HasColumnName("Status");
			this.Property(t => t.OldPoint).HasColumnName("OldPoint");
			this.Property(t => t.NewPoint).HasColumnName("NewPoint");
			this.Property(t => t.Operator).HasColumnName("Operator");
			this.Property(t => t.OperatDept).HasColumnName("OperatDept");
			this.Property(t => t.OperateTime).HasColumnName("OperateTime");
			this.Property(t => t.OperatorName).HasColumnName("OperatorName");
			this.Property(t => t.AudiDesc).HasColumnName("AudiDesc");
		}
	}
}

